package top.jiangqiang.sentinel.feign.consumer;

import lombok.RequiredArgsConstructor;
import org.springframework.web.bind.annotation.RequestMapping;
import org.springframework.web.bind.annotation.RestController;

@RestController
@RequestMapping("/")
@RequiredArgsConstructor
public class TestController {

    private final FeignService feignService;

    /**
     * 支持熔断降级
     * @return
     */
    @RequestMapping(value = "/getPort1")
    public String getPort1() {
        return "Feign:" + feignService.getPort();
    }
}